/**
 * @Author: zhoujie
 * @Date: 2019/08/24
 * @Last Modified by: mikey.zhaopeng
 * @Last Modified time: 2019-12-19 18:22:17
 */

const RouteView = () => import('@/layout/RouteView');
// 异步路由组件加载
const AsyncComponent = __name__ => () => import(`@/pages/${__name__}`);

/** 报表 菜单路由 */
const menuRoutes = [
  /** 报表管理 S */
  {
    path: '/report',
    meta: { title: '报表管理', icon: 'el-icon-warning-outline' },
    redirect: '/report',
    component: RouteView,
    children: [
      {
        path: '/report/repair',
        meta: { title: '维修报表' },
        redirect: '/report/repair',
        component: RouteView,
        children: [
          {
            path: '/report/repair/repairBusiness',
            meta: { title: '维修业务报表', keepAlive: true },
            component: AsyncComponent('report/repair/repairBusiness')
          },
          {
            path: '/report/repair/repairprojects',
            meta: { title: '维修项目统计', keepAlive: true },
            component: AsyncComponent('report/repair/repairprojects')
          },
          {
            path: '/report/repair/claimDaily',
            meta: { title: '索赔日报表', keepAlive: true },
            component: AsyncComponent('report/repair/claimDailyboard')
          },
          {
            path: '/report/repair/ownerInformation',
            meta: { title: '车主车辆资料查询', keepAlive: true },
            component: AsyncComponent('report/repair/ownerInformation')
          },
          {
            path: '/report/repair/whereabouts',
            meta: { title: '维修配件去向查询', keepAlive: true },
            component: AsyncComponent('report/repair/whereabouts')
          },
          {
            path: '/report/repair/consultantVehicle',
            meta: { title: '服务顾问车辆查询', keepAlive: true },
            component: AsyncComponent('report/repair/consultantVehicle')
          },
          {
            path: '/report/repair/technician',
            meta: { title: '技师维修台次统计', keepAlive: true },
            component: AsyncComponent('report/repair/technician')
          },
          {
            path: '/report/repair/vehiclesMonthly',
            meta: { title: '进厂车辆月报', keepAlive: true },
            component: AsyncComponent('report/repair/vehiclesMonthly')
          },
          {
            path: '/report/repair/repairCost',
            meta: { title: '维修业务成本查询', keepAlive: true },
            component: AsyncComponent('report/repair/repairCost')
          },
          {
            path: '/report/repair/claimMonthly',
            meta: { title: '索赔月报表', keepAlive: true },
            component: AsyncComponent('report/repair/claimMonthly')
          },
          {
            path: '/report/repair/vehiclesDaily',
            meta: { title: '进厂车辆日报', keepAlive: true },
            component: AsyncComponent('report/repair/vehiclesDaily')
          },
          {
            path: '/report/repair/vehiclesStatistical',
            meta: { title: '车辆统计报表', keepAlive: true },
            component: AsyncComponent('report/repair/vehiclesStatistical')
          }
        ]
      },
      {
        path: '/report/part',
        meta: { title: '配件报表' },
        redirect: '/report/part',
        component: RouteView,
        children: [
          {
            path: '/report/part/repairDispatch',
            meta: { title: '维修发料统计', keepAlive: true },
            component: AsyncComponent('report/part/repairDispatch')
          },
          {
            path: '/report/part/billSearchOfPartStorage',
            meta: { title: '出入库单据查询', keepAlive: true },
            component: AsyncComponent('report/part/billSearchOfPartStorage')
          },
          {
            path: '/report/part/procurement',
            meta: { title: '采购入库统计', keepAlive: true },
            component: AsyncComponent('report/part/procurement')
          },
          {
            path: '/report/part/transfersSituation',
            meta: { title: '调拨情况统计', keepAlive: true },
            component: AsyncComponent('report/part/transfersSituation')
          },
          {
            path: '/report/part/partInventoryInfo',
            meta: { title: '配件库存明细查询', keepAlive: true },
            component: AsyncComponent('report/part/partInventoryInfo')
          },
          {
            path: '/report/part/partPriceInfo',
            meta: { title: '配件销售价格查询', keepAlive: true },
            component: AsyncComponent('report/part/partPriceInfo')
          },
          {
            path: '/report/part/partSalesInfo',
            meta: { title: '配件销售统计', keepAlive: true },
            component: AsyncComponent('report/part/partSalesInfo')
          },
          {
            path: '/report/part/partEntersSellsSave',
            meta: { title: '配件进销存汇总', keepAlive: true },
            component: AsyncComponent('report/part/partEntersSellsSave')
          },
          {
            path: '/report/part/partInventoryRemind',
            meta: { title: '配件库存报警', keepAlive: true },
            component: AsyncComponent('report/part/partInventoryRemind')
          },
          {
            path: '/report/part/partOutbound',
            meta: { title: '配件出库排名', keepAlive: true },
            component: AsyncComponent('report/part/partOutbound')
          },
          {
            path: '/report/part/InternalRecipients',
            meta: { title: '内部领用统计', keepAlive: true },
            component: AsyncComponent('report/part/InternalRecipients')
          },
          {
            path: '/report/part/partMonthly',
            meta: { title: '配件月报表', keepAlive: true },
            component: AsyncComponent('report/part/partMonthly')
          },
          {
            path: '/report/part/partEntersSellsSaveInfo',
            meta: { title: '配件进销存明细', keepAlive: true },
            component: AsyncComponent('report/part/partEntersSellsSaveInfo')
          },
          {
            path: '/report/part/overflowDamageInfo',
            meta: { title: '报溢报损统计', keepAlive: true },
            component: AsyncComponent('report/part/overflowDamageInfo')
          },
          {
            path: '/report/part/customerFastFluid',
            meta: { title: '客户快流件渗透率报表', keepAlive: true },
            component: AsyncComponent('report/part/customerFastFluid')
          }
        ]
      },
      {
        path: '/report/finance',
        meta: { title: '财务报表' },
        redirect: '/report/finance',
        component: RouteView,
        children: [
          {
            path: '/report/finance/settlementDetails',
            meta: { title: '结算单明细查询', keepAlive: true },
            component: AsyncComponent('report/finance/settlementDetails')
          },
          {
            path: '/report/finance/receipts',
            meta: { title: '收款情况查询', keepAlive: true },
            component: AsyncComponent('report/finance/receipts')
          },
          {
            path: '/report/finance/settlementRepair',
            meta: { title: '结算单维修项目统计', keepAlive: true },
            component: AsyncComponent('report/finance/settlementRepair')
          },
          {
            path: '/report/finance/preferences',
            meta: { title: '优惠情况查询', keepAlive: true },
            component: AsyncComponent('report/finance/preferences')
          },
          {
            path: '/report/finance/informationDetail',
            meta: { title: '欠帐信息查询', keepAlive: true },
            component: AsyncComponent('report/finance/informationDetail')
          },
          {
            path: '/report/finance/reduction',
            meta: { title: '减免情况查询', keepAlive: true },
            component: AsyncComponent('report/finance/reduction')
          },
          {
            path: '/report/finance/vehicleCost',
            meta: { title: '单车成本查询', keepAlive: true },
            component: AsyncComponent('report/finance/vehicleCost')
          },
          {
            path: '/report/finance/feeSettlement',
            meta: { title: '收费对象结算明细查询', keepAlive: true },
            component: AsyncComponent('report/finance/feeSettlement')
          },
          {
            path: '/report/finance/zeroRemoval',
            meta: { title: '去零情况查询', keepAlive: true },
            component: AsyncComponent('report/finance/zeroRemoval')
          },
          {
            path: '/report/finance/vehicleProfits',
            meta: { title: '单车毛利报表', keepAlive: true },
            component: AsyncComponent('report/finance/vehicleProfits')
          }
        ]
      },
      {
        path: '/report/workshop',
        meta: { title: '车间报表' },
        redirect: '/report/workshop',
        component: RouteView,
        children: [
          {
            path: '/report/workshop/waiterPerformance',
            meta: { title: '服务专员绩效统计表', keepAlive: true },
            component: AsyncComponent('report/workshop/waiterPerformance')
          },
          {
            path: '/report/workshop/technicianHours',
            meta: { title: '技师工时统计表', keepAlive: true },
            component: AsyncComponent('report/workshop/technicianHours')
          },
          {
            path: '/report/workshop/technicianReceive',
            meta: { title: '技师领料统计', keepAlive: true },
            component: AsyncComponent('report/workshop/technicianReceive')
          }
        ]
      },
      {
        path: '/report/summary',
        meta: { title: '汇总统计' },
        redirect: '/report/summary',
        component: RouteView,
        children: [
          {
            path: '/report/summary/consultantBack',
            meta: { title: '服务顾问半年回厂率统计', keepAlive: true },
            component: AsyncComponent('report/summary/consultantBack')
          },
          {
            path: '/report/summary/consultantVehicle',
            meta: { title: '服务顾问进厂台次细分统计', keepAlive: true },
            component: AsyncComponent('report/summary/consultantVehicle')
          },
          {
            path: '/report/summary/customerMileage',
            meta: { title: '客户行驶里程与保养分析', keepAlive: true },
            component: AsyncComponent('report/summary/customerMileage')
          }
        ]
      },
      {
        path: '/report/retail',
        meta: { title: '销售报表' },
        redirect: '/report/retail',
        component: RouteView,
        children: [
          {
            path: '/report/retail/potenCusInsertStat/index',
            meta: { title: '新增潜客分析', keepAlive: true },
            component: AsyncComponent('report/retail/potenCusInsertStat/index')
          },
          {
            path: '/report/retail/clueFunnelAnalysis/index',
            meta: { title: '线索漏斗分析', keepAlive: true },
            component: AsyncComponent('report/retail/clueFunnelAnalysis/index')
          },
          {
            path: '/report/retail/customerSalesFunnelAnalysis/index',
            meta: { title: '客源销售漏斗分析', keepAlive: true },
            component: AsyncComponent('report/retail/customerSalesFunnelAnalysis/index')
          },
          {
            path: '/report/retail/PerformanceReport/index',
            meta: { title: '销售顾问绩效对比报告', keepAlive: true },
            component: AsyncComponent('report/retail/PerformanceReport/index')
          },
          {
            path: '/report/retail/summaryOfDealerBriefing/index',
            meta: { title: '经销商简报汇总', keepAlive: true },
            component: AsyncComponent('report/retail/summaryOfDealerBriefing/index')
          },
          {
            path: '/report/retail/clueFunnelAnalysisOEM/index',
            meta: { title: '线索漏斗分析', keepAlive: true },
            component: AsyncComponent('report/retail/clueFunnelAnalysisOEM/index')
          },
          {
            path: '/report/retail/CauseOfDefeat/index',
            meta: { title: '战败原因分析', keepAlive: true },
            component: AsyncComponent('report/retail/CauseOfDefeat/index')
          },
          {
            path: '/report/retail/DefeatedCustomers/index',
            meta: { title: '战败客户明细', keepAlive: true },
            component: AsyncComponent('report/retail/DefeatedCustomers/index')
          },
          {
            path: '/report/retail/OrderAnalysis/index',
            meta: { title: '新增订单分析', keepAlive: true },
            component: AsyncComponent('report/retail/OrderAnalysis/index')
          },
          {
            path: '/report/retail/OrderAnalysisOEM/index',
            meta: { title: '新增订单分析', keepAlive: true },
            component: AsyncComponent('report/retail/OrderAnalysisOEM/index')
          },
          {
            path: '/report/retail/SalesVolumeAnalysis/index',
            meta: { title: '整车销量分析', keepAlive: true },
            component: AsyncComponent('report/retail/SalesVolumeAnalysis/index')
          },
        ]
      }
    ]
  }
  /** 报表管理 E */
];

export default menuRoutes;
